--- title: "L1-023 输出GPLT" created: 2025-11-28 tags: - 算法 --- # L1-023 输出GPLT ## 题目 [L1-023 输出GPLT](https://pintia.cn/problem-sets/994805046380707840/exam/problems/type/7?problemSetProblemId=994805113036587008&page=0) ![[image-c1a20754.png]] ## 思路分析 ## 代码实现 ```cpp #include using namespace std; #define endl '\n' int main() { ios::sync_with_stdio(0),cin.tie(0),cout.tie(0); string s;cin>>s; map hx; for(auto c:s){ hx[toupper(c)]++; } int maxn=max({hx['G'],hx['P'],hx['L'],hx['T']}); // cout<